{% extends 'base_home.html' %}
{% load static %}
{% load future %}
{% load widget_tweaks %}
{% block content %}
    <div class="container">
      <div class="starter-template">
        <h1>Page Contact </h1>
            <form action="{% url 'contact_index_page' %}" method="post" role="form" class="form-horizontal">
                  {% csrf_token %}
                  <div class="form-group">
                    <label for="inputEmail1" class="col-lg-2 control-label">Name</label>
                    <div class="col-lg-4">
                        <label > {{ form.name.errors }} </label>
                      {{ form.name|add_class:'form-control' }}
                    </div>
                  </div>
                  <div class="form-group">
                    <label for="inputEmail1" class="col-lg-2 control-label">Email</label>
                    <div class="col-lg-4">
                        <label > {{ form.email.errors }} </label>
                        {{ form.email|add_class:'form-control' }}
                    </div>
                  </div>
                  <div class="form-group">
                    <label for="inputEmail1" class="col-lg-2 control-label">Phone</label>
                    <div class="col-lg-4">
                        <label > {{ form.phone.errors }} </label>
                      {{ form.phone|add_class:'form-control' }}
                    </div>
                  </div>
                  <div class="form-group {% if form.subject.errors %} has-error {% endif %}"  >
                    <label for="inputEmail1" class="col-lg-2 control-label">Subject</label>
                    <div class="col-lg-4">
                       <label > {{ form.subject.errors }} </label>
                      {{ form.subject|add_class:'form-control' }}
                    </div>
                  </div>
                  <div class="form-group {% if form.messages.errors %} has-error {% endif %}">
                    <label for="inputEmail1" class="col-lg-2 control-label">Messages</label>
                    <div class="col-lg-6">
                      <label > {{ form.messages.errors }} </label>
                      {{ form.messages|attr:'rows:10'|attr:'cols:2000'|add_class:'form-control' }}
                    </div>
                  </div>
                  <div class="form-group">
                    <div class="col-lg-offset-2 col-lg-10">
                      <input type="submit" class="btn btn-primary" value="Send message" />
                    </div>
                  </div>
            </form>
      </div>
    </div>

{% endblock %}